package tech.yqyl.solo;

import lombok.Data;
import tech.yqyl.StringUtil;

import java.io.File;
import java.util.ArrayList;
import java.util.List;

@Data
public class BlogInfo {
    public BlogInfo(String categories, Article article, File blogFile) {
        this.categories = categories;
        this.article = article;
        this.blogFile = blogFile;
    }
    private boolean readmeFlag = false;
    private List<WrapperContent> ctxList = new ArrayList<>();
    private Article article;
    private String categories;
    private File blogFile;

    public BlogInfo setReadMeFlag(){
        this.readmeFlag = true;
        return this;
    }

    public void push(String markdown, String htmlContent) {
        ctxList.add(new WrapperContent(markdown, htmlContent));
    }
}
